package filter;

import javax.servlet.*;
import javax.servlet.annotation.WebFilter;
import javax.servlet.annotation.WebInitParam;
import java.io.IOException;

/**
 * 08-Filter注解开发
 */
//@WebFilter("/*")
public class Demo09Filter implements Filter {

    @Override
    public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException {
        System.out.println("Demo09Filter 过滤");
        chain.doFilter(request, response);//相当于执行Demo01Servlet
        System.out.println("Demo09Filter 放行");

    }
}
